package com.dr.cmdb.query.controller;


import com.dr.cmdb.common.model.response.ApiResponse;
import com.dr.cmdb.facade.api.ModelApi;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import io.swagger.annotations.ApiParam;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.List;
import java.util.Map;

/**
 * @ProjectName: cmdb-query
 * @Package: com.dr.cmdb.query.controller
 * @Description: java类作用描述
 * @Author: duanrui
 * @CreateDate: 2021/4/21 22:08
 * @Version: 1.0
 * <p>
 * Copyright: Copyright (c) 2021
 */

@RestController
@Api(value = "/api/node", tags = "配置项管理")
@RequestMapping("/api/node")
public class CiItemController {
    @Autowired
    private ModelApi modelApi;
    @ApiOperation("查询列表")
    @GetMapping("/list")
    public ApiResponse<List<Object>> getList(
            @ApiParam(required = true, name = "searchParams", value = "查询参数")
            @RequestParam Map<String, Object> searchParams){
        return modelApi.getList(new HashMap<>());

    }
}
